package com.ysd.lis.entity.cri;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ysd.lis.entity.BaseEntity;
import com.ysd.lis.entity.BaseEntityJpa;
import io.swagger.models.auth.In;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.sql.Timestamp;
import java.time.LocalDateTime;

/**
 * <p>
 * 
 * </p>
 *
 * @author wanghuaixing
 * @since 2025-02-13
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("CRI_CRITICAL_REPORT")
@Entity
@Table(name = "CRI_CRITICAL_REPORT")
public class CriCriticalReport extends BaseEntityJpa {

    private static final long serialVersionUID = 1L;

    /**
     * 病历号
     */
    @Column(name = "PAT_NO")
    @TableField("PAT_NO")
    private String patNo;

    /**
     * 姓名
     */
    @Column(name = "PAT_NA")
    @TableField("PAT_NA")
    private String patNa;

    /**
     * 项目代码
     */
    @Column(name = "ITEM_NO")
    @TableField("ITEM_NO")
    private String itemNo;

    /**
     * 报告内容
     */
    @Column(name = "REPORT_VAL")
    @TableField("REPORT_VAL")
    private String reportVal;

    /**
     * 危急值结果
     */
    @Column(name = "CURRENT_RESULT")
    @TableField("CURRENT_RESULT")
    private String currentResult;

    /**
     * 科室
     */
    @Column(name = "DEPT_NO")
    @TableField("DEPT_NO")
    private String deptNo;

    /**
     * 床号
     */
    @Column(name = "BED_NO")
    @TableField("BED_NO")
    private String bedNo;


    /**
     * 申请单号
     */
    @Column(name = "REQUEST_NO")
    @TableField("REQUEST_NO")
    private String requestNo;

    /**
     * 危急值的唯一号
     */
    @Column(name = "CRITICAL_NO")
    @TableField("CRITICAL_NO")
    private String criticalNo;

    /**
     * 备注
     */
    @Column(name = "REMARK")
    @TableField("REMARK")
    private String remark;

    /**
     * 通知方式
     */
    @Column(name = "NOTIFICATION_TYPE")
    @TableField("NOTIFICATION_TYPE")
    private String notificationType;

    /**
     * 危急值类型:1检验 2细菌
     */
    @Column(name = "CRITICAL_TYPE")
    @TableField("CRITICAL_TYPE")
    private Double criticalType;

    /**
     * 危急值项目类型:1血培养 2形态镜像 3敏鉴 4药敏
     */
    @Column(name = "CULTICAL_ITEM_TYPE")
    @TableField("CULTICAL_ITEM_TYPE")
    private Double culticalItemType;

    /**
     * 项目名称
     */
    @Column(name = "ITEM_NA")
    @TableField("ITEM_NA")
    private String itemNa;

    /**
     * 危急值系统名称（哪个系统过来的）
     */
    @Column(name = "SYSTEM_NO")
    @TableField("SYSTEM_NO")
    private String systemNo;

    /**
     * 危急值系统地址
     */
    @Column(name = "SYSTEM_URL")
    @TableField("SYSTEM_URL")
    private String systemUrl;

    /**
     * 上报人
     */
    @Column(name = "REPORT_PERSON_NO")
    @TableField("REPORT_PERSON_NO")
    private String reportPersonNo;

    /**
     * 上报科室编码
     */
    @Column(name = "REPORT_PERSON_NA")
    @TableField("REPORT_PERSON_NA")
    private String reportPersonNa;

    /**
     * 上报科室名称
     */
    @Column(name = "REPORT_DEPT_NO")
    @TableField("REPORT_DEPT_NO")
    private String reportDeptNo;

    /**
     * 上报科室名称
     */
    @Column(name = "REPORT_DEPT_NA")
    @TableField("REPORT_DEPT_NA")
    private String reportDeptNa;

    /**
     * 上报时间
     */
    @Column(name = "REPORT_TIME")
    @TableField("REPORT_TIME")
    private Timestamp reportTime;

    /**
     * 护士编号
     */
    @Column(name = "NURSE_PERSON")
    @TableField("NURSE_PERSON")
    private String nursePerson;


    /**
     * 护士通知时间
     */
    @Column(name = "NURSE_REPORT_TIME")
    @TableField("NURSE_REPORT_TIME")
    private Timestamp nurseReportTime;

    /**
     * 护士处理时间
     */
    @Column(name = "NURSE_TIME")
    @TableField("NURSE_TIME")
    private Timestamp nurseTime;


    /**
     * 医生编号
     */
    @Column(name = "DOCTOR_PERSON")
    @TableField("DOCTOR_PERSON")
    private String doctorPerson;


    /**
     * 医生通知时间
     */
    @Column(name = "DOCTOR_REPORT_TIME")
    @TableField("DOCTOR_REPORT_TIME")
    private Timestamp doctorReportTime;

    /**
     * 审核人
     */
    @Column(name = "REVIEWER_DOCTOR")
    @TableField("REVIEWER_DOCTOR")
    private String reviewerDoctor;

    /**
     * 审核时间
     */
    @Column(name = "REVIEWER_TIME")
    @TableField("REVIEWER_TIME")
    private Timestamp reviewerTime;
    /**
     * 临床处理措施
     */
    @Column(name = "TREATMENT_MEASURE")
    @TableField("TREATMENT_MEASURE")
    private String treatmentMeasure;


    /**
     * 状态(0未发布,10通知护士,20通知医生)
     */
    @Column(name = "STATE_CODE")
    @TableField("STATE_CODE")
    private Integer stateCode;

    @TableField("SEX")
    @Column(name = "SEX")
    private String sex;

    @TableField("AGE")
    @Column(name = "AGE")
    private Integer age;

    @TableField("AGE_UNIT")
    @Column(name = "AGE_UNIT")
    private String ageUnit;

    @TableField("PAT_TYPE")
    @Column(name = "PAT_TYPE")
    private String patType;

    @TableField("REQ_DOCTOR")
    @Column(name = "REQ_DOCTOR")
    private String reqDoctor;

    /**
     * 项目异常
     */
    @Transient
    @TableField(exist = false)
    private String itemException;
    /**
     * 项目异常
     */
    @Transient
    @TableField(exist = false)
    private String stateNa;

    @Transient
    @TableField(exist = false)
    private String doctorPersonName;



}
